package cn.weiron.fun.sample.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * @author  weiRon
 * @date  2022/9/26 15:35
 */
@Data
@TableName(value = "sample_time_record")
public class SampleTimeRecord {
    @TableId(value = "id", type = IdType.INPUT)
    private Long id;

    /**
     * 点位唯一Id
     */
    @TableField(value = "point_unique_id")
    private String pointUniqueId;

    /**
     * 开放时间
     */
    @TableField(value = "open_time")
    private String openTime;

    /**
     * 排班日期
     */
    @TableField(value = "date_time")
    private String dateTime;

    /**
     * 开放时长
     */
    @TableField(value = "hours")
    private Integer hours;

    /**
     * 当日单价
     */
    @TableField(value = "price")
    private BigDecimal price;

    /**
     * 记录创建时间
     */
    @TableField(value = "create_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

    /**
     * （预留）
     */
    @TableField(value = "deductions")
    private BigDecimal deductions;

    /**
     * （预留）
     */
    @TableField(value = "reason")
    private String reason;

    /**
     * 年份
     */
    @TableField(value = "t_year")
    private String year;

    /**
     * 月份
     */
    @TableField(value = "t_month")
    private String month;

    /**
     * 日期
     */
    @TableField(value = "t_day")
    private String day;

    public static final String COL_ID = "id";

    public static final String COL_POINT_UNIQUE_ID = "point_unique_id";

    public static final String COL_OPEN_TIME = "open_time";

    public static final String COL_DATE_TIME = "date_time";

    public static final String COL_HOURS = "hours";

    public static final String COL_PRICE = "price";

    public static final String COL_CREATE_TIME = "create_time";

    public static final String COL_DEDUCTIONS = "deductions";

    public static final String COL_REASON = "reason";

    public static final String COL_YEAR = "t_year";

    public static final String COL_MONTH = "t_month";

    public static final String COL_DAY = "t_day";


}